home *** CD-ROM | disk | FTP | other *** search
Text File | 1995-06-10 | 1.9 KB | 85 lines | [TEXT/MWPS] |
- program FamilyTree;
-
- uses
- UFamily;
-
- type
-
- TFamilyApp = object(TApplication)
-
- procedure TFamilyApp.Init;
-
- function TFamilyApp.DoMakeDocument (itsCmdNumber: CmdNumber): TDocument;
- OVERRIDE;
- procedure TFamilyApp.DoShowAboutApp;
- OVERRIDE;
- end;
-
-
- var
- gApp: TFamilyApp;
-
- {==========================================================================}
- { A p p l i c a t i o n }
- {==========================================================================}
- procedure TFamilyApp.Init;
- begin
- IApplication(kFileType);
- {$IFC false}
- EnterMacAppDebugger;
- {$ENDC}
- fLaunchWithNewDocument := false;
- InitMyDialogs;
-
- if gDeadStripSuppression then
- begin
- if Member(TObject(nil), TFamilyView) then
- ;
- if Member(TObject(nil), TActiveText) then
- ;
- if Member(TObject(nil), TPersonCluster) then
- ;
- end;
- end;
-
-
- function TFamilyApp.DoMakeDocument (itsCmdNumber: CmdNumber): TDocument;
- OVERRIDE;
- var
- D: TFamilyDoc;
- begin
- New(D);
- FailNil(D);
-
- D.Init;
- DoMakeDocument := D;
- end;
-
- procedure TFamilyApp.DoShowAboutApp;
- OVERRIDE;
- begin
- {if MacAppAlert(phAboutApp, nil) = 2 then}
- StdAlert(phAboutApp);
- end;
-
- {===========================================================================}
- { M a i n }
- {===========================================================================}
- begin
- InitToolBox; { Essential toolbox and utilities initialization }
- if ValidateConfiguration(gConfiguration) then { Make sure we can run }
- begin
- InitUMacApp(20); { Initialize MacApp; 20 calls to MoreMasters}
- {InitUPrinting; NOT USED}
- InitUTEView; { Initialize the TEView unit }
- InitUDialog; { Initialize the Dialog unit }
- InitUGridView;
-
- New(gApp); { Create an application object }
- FailNil(gApp);
- gApp.init; { Initialize the application }
- gApp.Run; { Run the application }
- end
- else
- StdAlert(phUnsupportedConfiguration);
- end.